<template>
	<view>	
		<button @click="openConversationList">打开会话列表</button>
		<button @click="openContact">打开联系人</button>
		<button @click="c2c">跟双聊天</button>
	</view>
</template>

<script>
	import {
		parseQuery
	} from '@/utils/index.js'
	
	const {
		appid
	} = parseQuery()
	
	export default {
		methods: {
			// 打开会话列表
			openConversationList() {
				uni.navigateTo({
					url: `/TUIKit/components/TUIConversation/index?appid=${appid}&key=pc`
				});
			},
			// 打开联系人
			openContact() {
				uni.navigateTo({
					url: `/TUIKit/components/TUIContact/index?appid=${appid}&key=pc`
				});
			},
			c2c() {
				const conversationID = `C2Cmumaren`;
				uni.navigateTo({ url: `/TUIKit/components/TUIChat/index?appid=${appid}&key=pc&conversationID=${conversationID}`});
			}
		},
	};
</script>

<style>
</style>